package com.voxel.sense.infomsg.module.files;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.text.TextUtils;

import com.example.com.common.app.BaseActivity;
import com.voxel.sense.infomsg.R;

import cyy.example.com.facotry.constants.IntentConstants;

/**
 * Created by ChenYiYao on 2018/11/15.
 * des :
 */
public class LookPdfActivity extends BaseActivity {

    private String mFilePath;

    /**
     * @param context
     * @param path    文件绝对路径
     */
    public static void show(Context context, String path) {
        Intent intent = new Intent(context, LookPdfActivity.class);
        intent.putExtra(IntentConstants.STRING_TYPE, path);
        context.startActivity(intent);
    }

    @Override
    protected boolean initArgs(Bundle bundle) {
        mFilePath = getIntent().getStringExtra(IntentConstants.STRING_TYPE);
        return !TextUtils.isEmpty(mFilePath);

    }

    @Override
    protected int getContentLayoutId() {
        return R.layout.activity_look_pdf;
    }
}
